package com.allenkerr.app;

import com.webxml.chinese.TraditionalSimplifiedWebService;
import com.webxml.chinese.TraditionalSimplifiedWebServiceSoap;

/**
 * Created by 小柯(Allen Kerr) on 17.5.16 10:21.
 */
public class ChineseConversionApp {

    public static void toTraditionalChinese(String simplifiedChinese) {
        System.out.println("简体转繁体：");
        TraditionalSimplifiedWebService webService = new TraditionalSimplifiedWebService();
        TraditionalSimplifiedWebServiceSoap soap = webService.getTraditionalSimplifiedWebServiceSoap();
        String result = soap.toTraditionalChinese(simplifiedChinese);
        System.out.println(simplifiedChinese + " ==> " + result);
    }

    public static void toSimplifiedChinese(String traditionalChinese) {
        System.out.println("繁体转简体：");
        TraditionalSimplifiedWebService webService = new TraditionalSimplifiedWebService();
        TraditionalSimplifiedWebServiceSoap soap = webService.getTraditionalSimplifiedWebServiceSoap();
        String result = soap.toSimplifiedChinese(traditionalChinese);
        System.out.println(traditionalChinese + " ==> " + result);
    }

}
